# -*- coding: utf-8 -*-

# 
# this is plugin example for duu, 
#
# Created: Thu Apr 21 12:50:32 2011
#      
#  
#  date             author          issues
#  2011-Apr-21   Wan            creator
#
#
#


import os, sys, unittest

class   duu(unittest.TestCase):
    ui = None
    
    def setUI(self,  ui = None):
        duu.ui = ui
        
    def setUp(self):
        if duu.ui == None:
            raise RuntimeError
        duu.ui.printLog("*************** test case begin **************")
        
    def tearDown(self):
        duu.ui.printLog("**************** test case end *********************")
            
    def test_init(self):
        """
        analyze the configure file,  it's called by framework, mandotory!!!
        """
        duu.ui.printLog("%s - %s"%(__file__, sys._getframe().f_code.co_name ))           
        
    def test_run(self):
        """
        running logic for plugin, it's called by framwork, mandotory!!!
        """
        duu.ui.printLog("%s - %s"%(__file__, sys._getframe().f_code.co_name ))    
             
if __name__ == "__main__":
    unittest.main()             
